-- GENERATED SPELL FOR [Razzashi Raptor] --


function spell0_14821(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(8599,pUnit)
pUnit:RegisterEvent('Sorts_14821', 630, 1)
end

function spell1_14821(pUnit, Event) --@Infected Bite,n/a--
pUnit:FullCastSpellOnTarget(24339,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_14821', 0, 1)
end

function spell2_14821(pUnit, Event) --@Thrash,Self--
pUnit:FullCastSpellOnTarget(3391,pUnit)
pUnit:RegisterEvent('Sorts_14821', 584, 1)
end

function Sorts_14821(pUnit, Event)
local choix_sorts_14821 = math.random(0, 2)
if choix_sorts_14821 == 0 then
pUnit:RegisterEvent('spell0_14821', 1, 1)
end
if choix_sorts_14821 == 1 then
pUnit:RegisterEvent('spell1_14821', 1, 1)
end
if choix_sorts_14821 == 2 then
pUnit:RegisterEvent('spell2_14821', 1, 1)
end
end

function mob14821_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_14821', math.random(1500, 3000), 1)
end

function mob14821_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob14821_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob14821_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(14821, 1, 'mob14821_Action')
RegisterUnitEvent(14821, 2, 'mob14821_Leave')
RegisterUnitEvent(14821, 3, 'mob14821_Kill')
RegisterUnitEvent(14821, 4, 'mob14821_Die')
